import useInstance from "./useInstance";

export default function () {
    const current = useInstance();

    return (type, message) => {
        current.$message({
            type: (!message && "success") || type,
            message: message || type,
        });
    };
}
